package smetana.modules;

import com.google.inject.Guice;
import com.google.inject.Injector;
import com.google.inject.Stage;
import smetana.modules.business.ModuleBusiness;
import smetana.modules.ui.UIModule;

/**
 *
 * @author dmitry.mamonov
 */
public class App {

    static Injector delegate = null;

    private App() {
    }

    public static Injector injector() {
        if (delegate == null) {
            ModuleBusiness businessModule = new ModuleBusiness();
            UIModule uIModule = new UIModule();
            delegate = Guice.createInjector(Stage.DEVELOPMENT, businessModule, uIModule);
        }
        return delegate;
    }

}
